#!/usr/bin/python3.4
# -*- coding=utf-8 -*-

from pysnmp.hlapi import *

errorIndication, errorStatus, errorIndex, varBinds = next(
    getCmd(SnmpEngine(),
           CommunityData('qytangro'),
           UdpTransportTarget(('202.100.1.1', 161)),
           ContextData(),
           ObjectType(ObjectIdentity('1.3.6.1.2.1.1.1.0')),
           ObjectType(ObjectIdentity('1.3.6.1.2.1.1.6.0')))
)

if errorIndication:
    print(errorIndication)
elif errorStatus:
    print('%s at %s' % (
            errorStatus.prettyPrint(),
            errorIndex and varBinds[int(errorIndex)-1][0] or '?'
        )
    )
else:
    for varBind in varBinds:
        print(' = '.join([ x.prettyPrint() for x in varBind ]))

==============================================================================
[root@Fedora pySNMP]# ./SNMPv2_Get.py 
SNMPv2-MIB::sysDescr.0 = Cisco IOS Software, 3600 Software (C3660-JK9O3S-M), Version 12.4(15)T5, RELEASE SOFTWARE (fc4)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2008 by Cisco Systems, Inc.
Compiled Wed 30-Apr-08 17:50 by prod_rel_team
SNMPv2-MIB::sysLocation.0 = qytangbeijing